<template>
  <div class="container">
    <div class="content">
      <div class="title">
        我的订单
      </div>
      <el-tabs
        v-model="filter.status"
        @tab-click="changeStatus"
      >
        <el-tab-pane
          v-for="item in status_array"
          :key="item.code"
          :label="item.name"
          :name="item.code"
        ></el-tab-pane>
      </el-tabs>
      <div class="list">
        <div
          class="item"
          v-for="i in 7"
          :key="i"
        >
          <div class="row">
            <div class="col">
              <div class="label">结算商品：</div>
              <div class="text">追光者</div>
            </div>
          </div>
          <div class="row">
            <div class="col col2">
              <div class="label">销售总价：</div>
              <div class="text">15959.90</div>
            </div>
            <div class="col col2">
              <div class="label">利润总价：</div>
              <div class="text">5900.00</div>
            </div>
          </div>
          <div class="row">
            <div class="col col2">
              <div class="label">平台抽成：</div>
              <div class="text">1000.00（20%）</div>
            </div>
            <div class="col col2">
              <div class="label">结算价格：</div>
              <div class="text">4900.00</div>
            </div>
          </div>
          <div class="row">
            <div class="col">
              <div class="label">申请时间：</div>
              <div class="text">2021-09-15 22:10:12</div>
            </div>
          </div>
          <div class="status">
            未打款
          </div>
        </div>
      </div>
      <div class="page">
        <el-pagination
          background
          layout="total, prev, pager, next"
          :total="1000"
        >
        </el-pagination>
      </div>
    </div>
  </div>
</template>

<script>
export default {
  data() {
    return {
      status_array: [
        {
          code: '0',
          name: '全部（56）'
        },
        {
          code: '1',
          name: '未打款（12）'
        },
        {
          code: '2',
          name: '已打款（44）'
        }
      ],
      filter: {
        status: '0'
      }
    };
  },
  methods: {
    changeStatus() {}
  }
};
</script>

<style scoped>
.container {
  background: #f0f2f5;
  padding: 25px;
  font-size: 14px;
}
.container .content {
  background: #ffffff;
  padding-bottom: 40px;
}
.content .title {
  padding: 20px 30px;
  font-size: 20px;
  font-weight: bold;
  border-bottom: 1px solid #eee;
  color: #000000d8;
}
.content .el-tabs {
  padding: 10px 40px 0;
}

.list {
  display: flex;
  flex-wrap: wrap;
  padding: 10px 40px 0;
}
.list .item {
  width: 32%;
  margin-right: 2%;
  border: 1px solid #eee;
  margin-bottom: 30px;
  padding-top: 10px;
  display: flex;
  flex-direction: column;
  color: #7f7f7f;
}
.item:hover {
  box-shadow: 1px 1px 5px #888888;
}
.item:nth-child(3n) {
  margin-right: 0;
}

.row:first-child {
  padding-bottom: 15px;
}

.row:first-child .text {
  font-size: 16px;
  font-weight: bold;
}

.row {
  display: flex;
  justify-content: space-between;
  padding: 0 10px 6px;
}
.row .col {
  display: flex;
  width: 100%;
}
.col .label {
  width: 70px;
  flex-shrink: 0;
}
.col .text {
  flex-grow: 1;
}
.col2:nth-child(2) {
  width: 40%;
  text-align: right;
}
.status {
  padding: 15px 0;
  text-align: center;
  border-top: 1px solid #eee;
  background: #f7f9fa;
}
.status.success {
  color: #67c23a;
}
.page {
  text-align: center;
}
</style>